<!DOCTYPE html>
<script src="../../../resources/js-test.js"></script>
<script>

description('Ensures that we get exceptions when we do not include required arguments for localStorage methods.');

shouldThrow('localStorage.key()', '"TypeError: Failed to execute \'key\' on \'Storage\': 1 argument required, but only 0 present."');
shouldThrow('localStorage.getItem()', '"TypeError: Failed to execute \'getItem\' on \'Storage\': 1 argument required, but only 0 present."');
shouldThrow('localStorage.setItem()', '"TypeError: Failed to execute \'setItem\' on \'Storage\': 2 arguments required, but only 0 present."');
shouldThrow('localStorage.setItem("a")', '"TypeError: Failed to execute \'setItem\' on \'Storage\': 2 arguments required, but only 0 present."');
shouldThrow('localStorage.removeItem()', '"TypeError: Failed to execute \'removeItem\' on \'Storage\': 1 argument required, but only 0 present."');

</script>
